<!doctype html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>About Me - DGPT4537 Assignment</title>
    <!-- 引入Bootstrap CSS -->
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/css/bootstrap.min.css" rel="stylesheet">
    <style>
        body {
            background-color: #f8f9fa;
            color: #343a40;
        }
        .container {
            margin-top: 20px;
        }
        .info-section {
            padding: 20px;
            background-color: #fff;
            border-radius: 10px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
        }
        .contact-form {
            max-width: 600px;
            margin: 40px auto;
        }
        .home-link {
            display: block;
            margin-top: 20px;
        }
    </style>
</head>
<body>
    <!-- 使用Bootstrap的导航栏 -->
    <nav class="navbar navbar-expand-lg navbar-dark bg-dark fixed-top">
        <div class="container-fluid">
            <a class="navbar-brand" href="#">Hockey Heroes</a>
            <button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
                <span class="navbar-toggler-icon"></span>
            </button>
            <div class="collapse navbar-collapse" id="navbarNav">
                <ul class="navbar-nav ms-auto">
                    <li class="nav-item">
                        <a class="nav-link active" aria-current="page" href="/home">Home</a>
                    </li>
                    <li class="nav-item">
                        <a class="nav-link" href="/hockey">Heroes</a>
                    </li>
                    <li class="nav-item">
                        <a class="nav-link" href="/hockey/create">Create</a>
                    </li>
                    <li class="nav-item">
                        <a class="nav-link" href="/info">Info</a>
                    </li>
                </ul>
            </div>
        </div>
    </nav>

    <!-- 信息页面内容 -->
    <div class="container">
        <div class="info-section">
            <h1 class="text-center">About Me</h1>
            <p>Hi there! My name is xieyuhang, and I'm the creator of this Hockey Heroes website. I have a passion for web development and hockey, and this project combines both of my interests.</p>
            <p>I'm currently studying at dongguanzhiyejishuxueyuan and pursuing a degree in [Your Major]. In my free time, I enjoy playing hockey, coding, and exploring new technologies.</p>
            <p>If you have any questions or would like to get in touch with me, please feel free to use the contact form below:</p>
        </div>

        <!-- 联系表单 -->
        <div class="contact-form">
            <h2>Contact Form</h2>
            <form action="/submit-contact" method="post">
                <?= csrf_field() ?>

                <?php if (isset($errors)): ?>
                    <div class="alert alert-danger" role="alert">
                        <?php foreach ($errors as $error): ?>
                            <p><?= esc($error) ?></p>
                        <?php endforeach; ?>
                    </div>
                <?php endif; ?>

                <div class="mb-3">
                    <label for="name" class="form-label">Name</label>
                    <input type="text" class="form-control" id="name" name="name" required>
                </div>

                <div class="mb-3">
                    <label for="email" class="form-label">Email address</label>
                    <input type="email" class="form-control" id="email" name="email" required>
                </div>

                <div class="mb-3">
                    <label for="message" class="form-label">Message</label>
                    <textarea class="form-control" id="message" name="message" rows="5" required></textarea>
                </div>

                <button type="submit" class="btn btn-primary">Submit</button>
            </form>
        </div>

        <p class="text-center home-link">
            <a href="/home" class="btn btn-secondary">Home</a>
        </p>
    </div>

    <!-- 引入Bootstrap JS和依赖 -->
    <script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.11.6/dist/umd/popper.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0-alpha1/dist/js/bootstrap.min.js"></script>
</body>
</html>